Skip to content

feat: add comprehensive tests for facets#2

Open
0x0887 wants to merge 1 commit intogotchipus:mainfrom
0x0887:feature/0x0887
Open

feat: add comprehensive tests for facets#2
0x0887 wants to merge 1 commit intogotchipus:mainfrom
0x0887:feature/0x0887

Conversation

@0x0887
Copy link

@0x0887 0x0887 commented Jan 21, 2026

Added comprehensive tests for the core logic. Detailed coverage includes:

  • MintFacet.t.sol: Validates whitelist/public minting limits and payment logic (test_MintWhitelist, test_MintPublic), and the summoning process (test_SummonGotchipus).
  • AttributesFacet.t.sol: Tests interaction mechanics, including petting cooldowns (test_PetIncreaseStats) and name updates (test_SetName).
  • GotchiWearableFacet.t.sol: Verifies the full lifecycle of wearables: creation, minting, equipping, and unequipping (test_CreateAndMintWearable, test_EquipAndUnequip).
  • SvgFacetTest.t.sol: Mocks SVG storage and verifies the on-chain generation of the token SVG (testStoreSvg).
  • PaymasterFacet.t.sol: Tests ERC-4337 Paymaster execution and signature verification (test_ExecuteUserOp).
  • MetadataFacet.t.sol: Ensures tokenURI switches correctly from "pharos" to "gotchipus" endpoints after summoning (test_TokenURI).
  • HooksFacet.t.sol: Validates the registry logic for adding and removing execution hooks (test_AddAndRemoveHook).
  • GotchipusFacet.t.sol: Integration tests for token ownership, total supply, and white-list logic (testMint, testWhitelistMint).
  • DNAFacet.t.sol & TimeFacet.t.sol: Checks gene seeding logic (test_TokenGeneSeed) and global weather updates (test_UpdateWeather).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant